import React from 'react'

import {BASE_URL} from '../../utils/url'

// 导入校验propTypes
import PropTypes from 'prop-types'

import styles from './index.module.css'

function NoHouse ({children}) {
    return (
        <div className={styles.root}>
            <img className={styles.img} src={BASE_URL + `/img/not-found.png`} alt="未找到房源"/>
            <p className={styles.msg}>{children}</p>
        </div>
    )
}

NoHouse.propTypes= {
    // node表示任何数据类型都可以渲染
    children: PropTypes.node.isRequired
}
export default NoHouse